from flask import Flask
import mysql.connector

conn = mysql.connector.connect(host='127.0.0.1', port='3306', database='spider', user='root', password='123456',
                               use_unicode=True, auth_plugin='mysql_native_password')

app = Flask(__name__)

@app.route("/")
def hello_world():
	return "<p>Hello, World!</p>"


@app.route("/hello")
def hello_world3():
	c = conn.cursor()
	c.execute('''select * from river;''')
	cds = c.fetchall()
	print(cds)
	return cds[1][1]
